package com.serviceprovider.business.module.admin.faq.services.dao.interfaces;

//~--- non-JDK imports --------------------------------------------------------

import com.serviceprovider.business.module.admin.faq.model.Answer;
import com.serviceprovider.business.module.admin.faq.model.Category;
import com.serviceprovider.business.module.admin.faq.model.Faq;
import com.serviceprovider.business.module.admin.faq.model.Question;
import com.serviceprovider.business.module.common.Page;

//~--- JDK imports ------------------------------------------------------------

import java.util.List;

public interface IFaqService {
    void createCategory(Category category);

    void createQuestion(Question question);

    void createAnswer(Answer answer);

    void createFaq(Faq faq);

    void modifyCategory(Category category);

    void modifyQuestion(Question question);

    void rankQuestion(int questionId, int rank);

    void modifyQuestionFaq(int questionId, int isFaq);

    void modifyAnswer(Answer answer);

    void modifyFaq(Faq faq);

    void deleteCategory(int categoryId);

    void deleteQuestion(int questionId);

    void deleteAnswer(int answerId);

    void deleteFaq(int faqId);

    Category getCategory(int categoryId);

    Question getQuestion(int questionId);

    Answer getAnswer(int answerId);

    void rateAnswer(int answerId, int rate);

    Answer getAnswerForQuestion(int questionId);

    Faq getFaq(int faqId);

    List<Category> listCategories();

    Page<Category> listCategories(int pageNo, int recordSize, String sortColumn, String sortOrder);

    Page<Question> listQuestions(int categoryId, String refNumber, int pageNo, int recordSize, String sortColumn,
                                 String sortOrder);

    Page<Question> listQuestionsByUser(int userId, int pageNo, int recordSize, String sortColumn, String sortOrder);

    Page<Question> listRepliedQuestions(int categoryId, String refNumber, int pageNo, int recordSize,
            String sortColumn, String sortOrder);

    Page<Question> listUnansweredQuestions(int categoryId, String refNumber, int pageNo, int recordSize,
            String sortColumn, String sortOrder);

    List<Answer> listAnswers();

    List<Answer> listUsefulAnswers(int answerId);

    List<Answer> listTopTenAnswers();

    Page<Faq> listFaqs(int pageNo, int recordSize, String sortColumn, String sortOrder);

    Page<Answer> findAnswers(String keyword, int pageNo, int recordSize, String sortColumn, String sortOrder);
}



